home *** CD-ROM | disk | FTP | other *** search
- Path: fido.asd.sgi.com!austern
- From: Rob Stewart <stew@datalytics.com>
- Newsgroups: comp.std.c++
- Subject: Re: Suggestion to the C++ standard
- Date: 02 Apr 1996 16:52:06 PST
- Organization: Datalytics, Inc
- Approved: austern@isolde.mti.sgi.com
- Message-ID: <31616170.7BD7@datalytics.com>
- References: <4jatnm$s9b@post.tau.ac.il> <31599c95.4890732@nntp.ix.netcom.com> <315c0f6e.956220382@news.datalytics.com> <315cafc1.4316827@nntp.ix.netcom.com>
- NNTP-Posting-Host: isolde.mti.sgi.com
- X-Original-Date: Tue, 02 Apr 1996 12:18:40 -0500
- X-Mailer: Mozilla 2.0 (WinNT; I)
- X-Auth: PGPMoose V1.1 PGP comp.std.c++
- iQBVAwUBMWHLuEy4NqrwXLNJAQEKggH+Jh4U3aJM/2Kvjh32fnOx5H8w0AmGpCGC
- y9bkB8r6eSh8Ju2jkmxcl3mvGMOJylsRD8TIyvXNMp6Mc87nYYu0eg==
- =b2b6
- Originator: austern@isolde.mti.sgi.com
-
- Jason D. Morris wrote:
- >
- > On 29 Mar 1996 09:07:43 PST, davidb@datalytics.com (David Bradley)
- > wrote:
- >
- > >Lastly the naming of the data member/accessors breaks most common
- > >styles. Usually the member functions are distingiushed in some manner
- > >from the data members.
- >
- > If you mean not explicitly naming the get/set functions with get/set
- > tacked on the beginning of the name then yes, I agree that the
- > property template breaks with common style. Personally, I never use
- > get/set prefixes in any of the code that I write. When I do have
- > members that perform get/set operations I overload member function
- > acessors with names like those used by the property class. Client
- > code should never rely on any internal class implementation details;
- > only interfaces to the services provided by the class.
- >
-
- Consider a naming convention in which dms are prefixed with
- "m_." In that case, public dms would have names like "m_Data,"
- while the corresponding accessor/modifier mfs would be named
- "Data." Only when dms are named the same way as mfs would there
- be no problem recognizing that you just add parentheses to the
- dm name.
-
- --
- Robert Stewart | My opinions are usually my own.
- Datalytics, Inc. | stew@datalytics.com
- ---
- [ comp.std.c++ is moderated. To submit articles: Try just posting with your
- newsreader. If that fails, use mailto:std-c++@ncar.ucar.edu
- comp.std.c++ FAQ: http://reality.sgi.com/austern/std-c++/faq.html
- Moderation policy: http://reality.sgi.com/austern/std-c++/policy.html
- Comments? mailto:std-c++-request@ncar.ucar.edu
- ]
-